-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: support start time parameter on read changes #443
base: main
Are you sure you want to change the base?
feat: support start time parameter on read changes #443
Conversation
Minder Vulnerability Report ✅Minder analyzed this PR and found it does not add any new vulnerable dependencies.
|
feat: support start time parameter on read changes
20718e8
to
a1f7cbb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a query around the format the CLI accepts
if startTime != "" { | ||
layout := "2006-01-02T15:04:05Z" | ||
|
||
parsedTime, err := time.Parse(layout, startTime) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we be using time.RFC3339
here as that's what we use in the go-sdk, or is the 2006-01-02T15:04:05Z07:00
format a little bit too lengthy to write out on the CLI?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The API docs call for ISO8601 which in go requires a layout variable as it differs slightly from RFC3339. The go-sdk expects input to be a time.Time object but since we're taking text input in the CLI this ensures that ISO8601 is properly supported as detailed in the API documentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh my bad, I overlooked we were just using that in the tests
Co-authored-by: Ewan Harris <[email protected]>
Description
Adds support for start_time parameter in read changes
References
openfga/go-sdk#158
Review Checklist
main